from pydantic import BaseModel, EmailStr
from typing import Optional, List

# 创建通知的请求模型
class NotificationCreate(BaseModel):
    id: int
    email: str
    count: int
    
# 更新通知的请求模型
class NotificationUpdate(BaseModel):
    email: Optional[str] = None
    count: Optional[int] = None
    isDelete: Optional[bool] = None
    
# 通知的响应模型
class NotificationResponse(BaseModel):
    id: int
    email: str
    count: int
    isDelete: bool
    
    class Config:
        from_attributes = True